package com.sprouting.ops.model.bo;

import com.baomidou.mybatisplus.annotation.TableId;
import com.sprouting.ops.annotations.invoke.CheckLength;
import com.sprouting.ops.annotations.invoke.CheckNotNull;
import com.sprouting.ops.interfaces.AddGroup;
import com.sprouting.ops.interfaces.UpdGroup;
import lombok.Data;

import javax.validation.constraints.Null;

/**
 * 字典组
 *
 * @author ：LX（长沙麓谷）
 * @date 创建时间： 2025/8/14 22:58
 */
@Data
public class OpsSysDictGroupBo {

    /**
     * 主键
     */
    @CheckNotNull(message = "非法ID", groups = UpdGroup.class)
    @Null(message = "无效ID", groups = AddGroup.class)
    private String id;
    /**
     * 字典组代码-有且唯一，一组数字字符串
     */
    @CheckNotNull(message = "请输入字典组代码")
    @CheckLength(min = 1, max = 20, message = "字典组代码超过长度限制")
    private String code;
    /**
     * 字典组名称
     */
    @CheckNotNull(message = "请输入字典组名称")
    @CheckLength(min = 1, max = 150, message = "字典组名称超过长度限制")
    private String name;
    /**
     * 字典组描述
     */
    @CheckNotNull(message = "请输入字典组描述")
    @CheckLength(min = 1, max = 2000, message = "字典组描述超过长度限制")
    private String description;
    /**
     * 是否基础数据
     * @see com.sprouting.ops.interfaces.ConstantBase.BaseData
     */
    private Integer baseData;
    /**
     * 字典组排序，默认99
     * @see com.sprouting.ops.interfaces.ConstantBase.DefaultValue#SORT
     */
    private Double sort;
}
